package com.vlin.mapper.device;

import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Update;

import com.vlin.entity.device.DeviceStatu;

public interface DeviceStatusMapper {

	@Insert("insert into device_status(codes,cvalue,did,converts) values(#{code},#{value},#{did},#{converts})")
	public int insert(DeviceStatu statu);
	
	@Update("update device_status set codes=#{code},cvalue=#{value} where did=#{did} and codes=#{code}")
	public int update(DeviceStatu statu);
	
	@Insert("insert into device_status(codes,cvalue,did,converts,devid) values(#{code},#{value},#{did},#{converts},#{devid})")
	public int insertAndDevid(DeviceStatu statu);
	
	@Update("update device_status set codes=#{code},cvalue=#{value},devid=#{devid} where did=#{did} and codes=#{code}")
	public int updateAndDevid(DeviceStatu statu);

	
}
